/*
 ============================================================================
 Name		: UserDatabase.h
 Author	  : Lenka Litvova
 Version	 : 1.0
 Copyright   : Copyright belongs to Lenka Litvova
 Description : CUserDatabase declaration
 ============================================================================
 */

#ifndef USERDATABASE_H
#define USERDATABASE_H

// INCLUDES
#include <e32std.h>
#include <e32base.h>

#include "FaceGraph.h"

// CLASS DECLARATION

/**
 *  CUserDatabase
 * 
 */
class CUserDatabase : public CBase
	{
public:
	// Constructors and destructor

	/**
	 * Destructor.
	 */
	~CUserDatabase();

	/**
	 * Two-phased constructor.
	 */
	static CUserDatabase* NewL();

	/**
	 * Two-phased constructor.
	 */
	static CUserDatabase* NewLC();
	
	static TBool AddNewAuthorizedUser(CFaceGraph* aFace, TDesC &aUsername);
	
	static void DeleteAuthorizedUser(TDesC &aUsername);
	
	static TBool UserExists(TDesC &aUsername);
	
private:

	/**
	 * Constructor for performing 1st stage construction
	 */
	CUserDatabase();

	/**
	 * EPOC default constructor for performing 2nd stage construction
	 */
	void ConstructL();

	};

#endif // USERDATABASE_H
